import { http } from '@/utils/http'
import mccList from './json/getMcc.json'

/**
 * 获取行业类型
 * @returns ICaptcha 验证码
 */
export interface MccItem {
  id: number
  pid: number
  text: string
  value: string
  children?: MccItem[]
  [key: string]: any
}
interface MccList {
  code: number
  msg: string
  list: MccItem[]
}
export function getMcc(): any {
  // return http.get<MccItem[]>('/mch/tpl/getMcc.html')

  return new Promise((resolve) => {
    const res = mccList
    resolve(res)
  })
}

export function getTplList(params: any): any {
  params.act = 'get_data'
  return http.get('/mch/tpl/list.html', params)
}
